<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>数制转换</title>
</head>
<body>
	<h1>数制转换</h1><hr>
	<script type="text/javascript">
		document.write("32, 032, 0x32在不用情况下的转换结果: <br><br>");
		document.write("默认情况下的结果: ");
		document.write("32->" + parseInt('32'));
		document.write("; 032->" + parseInt('032'));
		document.write("; 0x32->" + parseInt('0x32') + "<br>");
		
		document.write("转换为二进制的结果: ");
		document.write("32->" + parseInt('32', 2));
		document.write("; 032->" + parseInt('032', 2));
		document.write("; 0x32->" + parseInt('0x32', 2) + "<br>");
		
		document.write("转换为八进制的结果: ");
		document.write("32->" + parseInt('32', 8));
		document.write("; 032->" + parseInt('032', 8));
		document.write("; 0x32->" + parseInt('0x32', 8) + "<br>");
		
		document.write("转换为十六进制的结果: ");
		document.write("32->" + parseInt('32', 16));
		document.write("; 032->" + parseInt('032', 16));
		document.write("; 0x32->" + parseInt('0x32', 16) + "<br><hr>");
		
		document.write("对1101101转换为不同进制的结果: <br><br>");
		//document.write("转换为: " + parseInt());
		
		
		
		
		
		
		
		
		
		
		
		
		
		
		
		
		
	</script>
</body>
</html>